import { defineStore } from "pinia";

const contestStore = defineStore("contest", {
  state: () => ({
    statusList: [
      {
        value: "1",
        label: "大赛未开始",
        color: "alert",
        btnLabel: "大赛未开始",
        btnDisabled: 1 as number | boolean,
      },
      { value: "2", label: "投稿中", color: "normal", btnLabel: "我要参赛", btnDisabled: 0 },
      { value: "3", label: "投票未开始", color: "normal", btnLabel: "投票未开始", btnDisabled: 2 },
      { value: "4", label: "投票中", color: "normal", btnLabel: "投票中", btnDisabled: 2 },
      { value: "5", label: "投票已结束", color: "gray", btnLabel: "投票已结束", btnDisabled: 1 },
      { value: "6", label: "大赛已结束", color: "gray", btnLabel: "大赛已结束", btnDisabled: 1 },
    ],
    userStatusList: [
      { value: "1", label: "已通过", color: "normal" },
      { value: "2", label: "未通过", color: "xred" },
      { value: "3", label: "审核中", color: "alert" },
      { value: "4", label: "已撤回", color: "gray" },
    ],
  }),
});

export { contestStore };
